/************************************************************
 * Project Name         [Thinking_In_Java]
 * File Name            [ImageScalingMain.java]
 * Creation Date        [10-Jul-2014]
 * 
 * Copyright© ge.y.yang@gmail.com All Rights Reserved
 * 
 * Work hard, play harder, think big and keep fit
 ************************************************************/
package pkg_02_gui.image_scaling;

/**
 * 
 * @author 不落的太阳(Sean Yang)
 * @version 1.0
 * @since JDK 6
 * 
 */
public class ImageScalingMain {

	/**
	 * 测试方法
	 * 
	 * @param args
	 *            命令行参数
	 */
	public static void main(String[] args) {

		ImageScaling jpg = new ImageScaling();
		// 将原图片缩小一半
		try {
			jpg.setPicScale(0.5);
			String srcFileName = "src_03_best_practices/pkg_02_gui/image_scaling/image1.jpg";
			String targetFileName = "src_03_best_practices/pkg_02_gui/image_scaling/image2.jpg";
			jpg.transform(srcFileName, targetFileName);
		} catch (Exception e) {
			e.printStackTrace();
		}
	}
}
